<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_content
 *
 * @copyright   Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */

defined('_JEXEC') or die;

$class = ' class="first"';
JHtml::_('bootstrap.tooltip');
$lang	= JFactory::getLanguage();
$i=1;
if (count($this->items[$this->parent->id]) > 0 && $this->maxLevelcat != 0) :
?>
	<?php foreach($this->items[$this->parent->id] as $id => $item) : ?>
		<?php
		if ($this->params->get('show_empty_categories_cat') || $item->numitems || count($item->getChildren())) :
		if (!isset($this->items[$this->parent->id][$id + 1]))
		{
			$class = ' class="last"';
		}
		?>
		<ul class="list-menu">
		<?php $class = ''; if($item->id== $id) $class=" class='active'"; ?>
			<li<?php echo $class;?>>
				<span><?php echo $i++;?></span><a href="<?php echo JRoute::_('index.php?option=com_content&view=categories&layout=service&id='.$this->parent->id.'&aid='.$item->id);?>">
				<?php echo $this->escape($item->title); ?></a>
			</li>		
		</ul>
		<?php endif; ?>
	<?php endforeach; ?>
<?php endif; ?>
